package com.example.rbacmanage.mapper.system;

import com.example.rbacmanage.base.BaseMapper;
import com.example.rbacmanage.entity.system.Role;
import com.example.rbacmanage.entity.system.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface UserMapper extends BaseMapper<User> {
    public User queryOneByUsername(@Param(value = "userName") String username);

    List<String> queryPermissionsByUserId(@Param("userId") Long userId);

    List<Role> queryRolesByUserId(@Param("userId")Long userId);

    List<User> selectListByRoleId(User user);

    List<User> selectListByNotRoleId(User user);
}
